// 通过这个方法，递归，生成用户的递归

const recursionRoutes=(menuList,routes)=>{
let userMenu=[];
menuList.forEach(menu => {
    routes.forEach(route => {
       if( menu.title===route.meta.title){
        route.meta.name=menu.name
        if(menu.children&&menu.children.length){
            route.children=recursionRoutes(menu.children,route.children)
        }
        userMenu.push(route)
       }
    })
})
return userMenu
}
export default recursionRoutes